<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<%@ page trimDirectiveWhitespaces="true"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="itheima" uri="http://itheima.com/common/"%>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://" + request.getServerName()
            + ":" + request.getServerPort() + path + "/";
%>

<div class="row">
    <div class="col-lg-12">
        <div class="panel panel-default">
            <div class="panel-heading">子功能列表</div>
            <!-- /.panel-heading -->
            <table class="table table-bordered table-striped">
                <thead>
                <tr>
                    <th>功能编号</th>
                    <th>功能名称</th>
                    <th>功能描述</th>
                    <th>功能路径</th>
                </tr>
                </thead>
                <tbody>
                <c:forEach items="${submoduleById}" var="submodule">
                    <tr>
                        <td>${submodule.function_id}</td>
                        <td>${submodule.function_name}</td>
                        <td>${submodule.function_desc}</td>
                        <td>${submodule.function_path}</td>
                        <td>
                            <a href="#" class="btn btn-primary btn-xs" data-toggle="modal"
                               data-target="#customerEditDialog" onclick="editUser(${role.role_id})">修改</a>
                            <a href="#" class="btn btn-danger btn-xs" onclick="deleteCustomer(${role.role_id})">删除</a>

                        </td>
                    </tr>
                </c:forEach>
                </tbody>
            </table>
            <!-- /.panel-body -->
        </div>
        <div class="panel panel-default">
            <div class="panel-heading">操作权限列表</div>
            <!-- /.panel-heading -->
            <table class="table table-bordered table-striped">
                <thead>
                <tr>
                    <th>权限编号</th>
                    <th>权限名称</th>
                    <th>权限描述</th>
                    <th>权限序号</th>
                    <th>操作</th>
                </tr>
                </thead>
                <tbody>
                <c:forEach items="${functionRightById}" var="functionRight">
                    <tr>
                        <td>${functionRight.right_id}</td>
                        <td>${functionRight.right_name}</td>
                        <td>${functionRight.right_desc}</td>
                        <td>${functionRight.right_order}</td>
                        <td>
                            <a href="#" class="btn btn-primary btn-xs" data-toggle="modal"
                               data-target="#customerEditDialog" onclick="editUser(${role.role_id})">修改</a>
                            <a href="#" class="btn btn-danger btn-xs" onclick="deleteCustomer(${role.role_id})">删除</a>

                        </td>
                    </tr>
                </c:forEach>
                </tbody>
            </table>
            <!-- /.panel-body -->
        </div>
        <!-- /.panel -->
    </div>
    <!-- /.col-lg-12 -->
</div>
</div>

</body>
</html>